package cn.jiyun.user.mapper;

import cn.jiyun.user.pojo.Users;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface UserMapper {

    @Insert("insert into users values(null,#{name},#{sex},#{pwd},#{birth})")
    void insertUser(Users users);

    @Select("select * from users")
    List<Users> selectAll();

    @Select("select * from users where name=#{name} and pwd=#{pwd}")
    Users login(Users users);
}
